module CommentsHelper
  def ispublished_column(record)
	  if !(record.ispublished)
	    
	    check_box_tag 'record[ispublished]'+record.id.to_s, record.id.to_s+' '+record.title+' '+Article.find(record.article_id).title, false,:onclick =>"selectInput(this.value);"
    else
	    check_box_tag 'record[ispublished]'+record.id.to_s, record.id.to_s+' '+record.title+' '+Article.find(record.article_id).title, true,:disabled=>true,:onclick =>"selectInput(this.value);"    
	  end
  end 

  def aliasn_form_column(record,input_name) 
  
   if logged_in_user.has_role?('administrator')


		    options = Ualia.find(:all).collect do |c| 
		      [ c.name, c.name ] 
		    end 
		    select :record, :aliasn, options, 
           {:include_blank => false}

   end      
  end
end
